package com.zufe.springdemo.mapper;

import com.zufe.springdemo.model.Information;
import com.zufe.springdemo.model.User;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface UserMapper {
    @Select("select * from user where user_id=#{userId}")
    User selectUser(int userId);
    @Select("select * from user")
    List<User> selectAllUser();
    @Select("select * from user u left outer join Information f on u.user_id=f.id;")
    List<Information> selectLeftOnUser();
}
